Some security cameras operate in one of two modes depending on the ambient lighting conditions. Day mode is used when there is sufficient ambient light to adequately illuminate the scene. Night mode (or IR mode) is used when there is not enough ambient light to adequately illuminate the scene, in which case the camera can provide its own IR illumination (e.g., using onboard IR LEDs).
One challenge for such cameras is deciding when to switch from Night mode to Day mode. Typically, Night mode is maintained until the camera detects an external light source that provides enough light for Day mode operation. This is a challenge in Night mode as the camera needs to evaluate the amount of visible ambient light from external light sources, but many light sources provide a combination of both IR and visible light, and in Night mode the camera sensor is responsive to both IR and visible light.
As a result, in a situation where a light source provides a high proportion of IR light in comparison to visible light, a camera in Night mode can switch into Day mode even though there is not enough visible ambient light to illuminate the scene. This can result in oscillations between Day mode and Night mode (e.g., after switching from Night to Day mode, the camera will determines that there is not enough visible light for Day mode operation, so will switch back to Night mode, and so on).
Traditional mode switching methods are also commonly fooled into switching from Night mode to Day mode in response to bright but narrow-beam light sources, such as flashlights or car headlights, that only provide light for a small portion of a scene. When exposed to such lights a camera will often switch to Day mode, which results in captured images being almost entirely dark due to lack of adequate ambient light.